<a href='http://github.com/angular/angular.js/edit/master/src/ng/http.js' class='improve-docs btn btn-primary'><i class="glyphicon glyphicon-edit">&nbsp;</i>Improve this doc</a>



<a href='http://github.com/angular/angular.js/tree/master/src/ng/http.js#L86' class='view-source pull-right btn btn-primary'>
  <i class="glyphicon glyphicon-zoom-in">&nbsp;</i>View Source
</a>


<header class="api-profile-header">
  <h1 class="api-profile-header-heading">$httpProvider</h1>
  <ol class="api-profile-header-structure naked-list step-list">
    
  <li>
    <a href="api/ng/service/$http">- $http</a>
  </li>

    <li>
      - provider in module <a href="api/ng">ng</a>
    </li>
  </ol>
</header>



<div class="api-profile-description">
  <p>Use <code>$httpProvider</code> to change the default behavior of the <a href="api/ng/service/$http">$http</a> service.</p>

</div>




<div>
  

    

  

  
  
  
<h2>Properties</h2>
<ul class="properties">
  <li id="defaults">
    <h3><code>defaults</code></h3>
    <table class="variables-matrix return-arguments">
  <tr>
    <td></td>
    <td><p>Object containing default values for all <a href="api/ng/service/$http">$http</a> requests.</p>
<ul>
<li><p><strong><code>defaults.xsrfCookieName</code></strong> - {string} - Name of cookie containing the XSRF token.
Defaults value is <code>&#39;XSRF-TOKEN&#39;</code>.</p>
</li>
<li><p><strong><code>defaults.xsrfHeaderName</code></strong> - {string} - Name of HTTP header to populate with the
XSRF token. Defaults value is <code>&#39;X-XSRF-TOKEN&#39;</code>.</p>
</li>
<li><p><strong><code>defaults.headers</code></strong> - {Object} - Default headers for all $http requests.
Refer to <a href="api/ng/service/$http#setting-http-headers">$http</a> for documentation on
setting default headers.</p>
<ul>
<li><strong><code>defaults.headers.common</code></strong></li>
<li><strong><code>defaults.headers.post</code></strong></li>
<li><strong><code>defaults.headers.put</code></strong></li>
<li><strong><code>defaults.headers.patch</code></strong></li>
</ul>
</li>
</ul>
</td>
  </tr>
</table>
  </li>
  </ul>



  
</div>


